Like most other programming languages, Kotlin supports while loops. The loop will execute each time the while expression returns true, exiting the loop once that expression returns false.

You can learn more about this in:
Run Expand Edit